class LoginModel {
  type!: string;
}
export interface UsernameLoginModel extends LoginModel {
  username: string;
  password: string;
}
export interface SmsLoginModel extends LoginModel {
  phone: string;
  captcha: string;
}
export interface EmailLoginModel extends LoginModel {
  email: string;
  captcha: string;
}
export interface AuthResponse {
    access_token?: string,
    refresh_token?: string
    scope?: string
    token_type?:string
    expires_in?: number
  
}
// 用户登录请求参数模型
export interface AuthRequestModel {
  username: string;
  password: string;
}

//Auth返回数据模型，返回token和用户信息
export interface AuthModel {
  token: string;
  userInfo: UserInfoModel;
}

/**
 * 用户模型
 */
export interface UserInfoModel {
  id:string
  name: string
  username: string
  email?: string
  phone?:string
  gender?: string
  age?: string
  avatar?: string 
  status?: string,
  source?: string
  referer?: string
  isVip?:string    
  city?: string
  sign?:string
  online?:boolean
  voiceUrl?:string
}

/**
 * 动态路由和权限模型
 */
export interface MenuPermissionsModel {
  menu: Menu.MenuOptions[];
  permissions: string[];
}

/**
 * 任务模型
 */
export interface TaskModel {
  id: string;
  taskName: string;
  type: string;
  result: string;
  state: string;
  stateName: string;
  createDate: string;
}

/**
 * 消息模型
 */
export interface MsgModel {
  id: number;
  type: string;
  avatar: string;
  title: string;
  describe: string;
  link: string;
  time: string;
}
